﻿using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
public class Navmenu : MonoBehaviour {

    // Use this for initialization
    void Start() {

    }

    // Update is called once per frame
    void Update() {

    }

    public void  click(){
       string btn_name = this.name;
        Debug.Log(btn_name);
        switch (btn_name)
        {
            case "btn_task":
                SceneManager.LoadScene("01_rwms");
                break;

            case "btn_ylfx":
                SceneManager.LoadScene("02_ylfx");
                break;
            case "btn_qjxy":
                SceneManager.LoadScene("03_qijian");
                break;
            case "btn_fzsx":
                SceneManager.LoadScene("04_anzhuang");
                break;
            case "btn_exam":
                SceneManager.LoadScene("05_exam");
                break;
            case "btn_fzyx":
                SceneManager.LoadScene("06_tiaoshi");
                break;
        }

    }

    public void btnHome() {
        Init.reset();
        SceneManager.LoadScene("u1_start");
        
    }

    public void btnExit()
    {
        Application.Quit();
    }

    public void btnFz() {
        SceneManager.LoadScene("06_tiaoshi");

    }

    public void btnHelp() {
        transform.Find("helpboard").gameObject.SetActive(true);
    }

    public void btnHelpClose() {
        transform.parent.gameObject.SetActive(false);
    }

}
